
//路由懒加载          import('') 语法返回一个 Promise 对象


const Recommend = () => import('@/components/recommend/Recommend')
const Rank = ()=>import('@/components/rank/Rank')
const Singer = ()=>import('@/components/singer/Singer')
const Search = ()=>import('@/components/search/Search')
const Detail = ()=>import('@/components/singer_detail/Detail')
const DiscSong = ()=>import('@/components/disc/DiscSong')
const RankDetail = ()=>import('@/components/rank-detail/RankDetail')
const User = ()=>import('@/components/user-center/User')

export default [
    {path: '/',redirect: '/recommend'},
    {path: '/recommend',component: Recommend,children: [
            {path: ':id',component: DiscSong,name:'disc'}
        ]},
    {path: '/rank',component: Rank,children: [
            {path: ':id',component: RankDetail,name:'rank-detail'}
        ]},
    {path: '/singer',component:Singer,children: [
            {path: ':id', component: Detail,name:'detail'}
        ]},
    {path: '/search',component: Search},
    {path: '/user',component: User}
]
